<?php
    include_once "bdmain.php"; //Conexion a BD
?>
<html>
<head>
    <title>TOP 5 GyM</title>
<style type="text/css">
body 
{
font: .75em/1.73em Verdana,Arial,Geneva,Helvetica,sans-serif;
color: #1E1E1E;
margin: 0px;
padding: 0px;
}
table 
{
display: table;
border-collapse: separate;
border-spacing: 2px 2px;
border-color: gray;
}


th 
{
font-weight: bold;
}

td, th 
{
display: table-cell;
vertical-align: inherit;
}

tfoot 
{
display: table-footer-group;
vertical-align: middle;
border-color: inherit;
text-align: right;
background-color:#FFFFFF;
}

#background-image tfoot td 
{
font-size: 11px;
}

#background-image th 
{
font-weight: normal;
font-size: 14px;
color: #339;
padding: 12px;
}
#background-image tbody tr:hover td 
{
color: #339;
background: none;
}
#background-image tbody td 
{
background: url("back.png");
}


#background-image td 
{
color: #669;
border-top: 1px solid white;
padding: 9px 12px;
}



tr 
{
display: table-row;
vertical-align: inherit;
border-color: inherit;
}




#background-image 
{
font-family: "Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
font-size: 12px;
width: 500px;
text-align: center;
border-collapse: collapse;
/*background: url("pi2.jpg") 330px 59px no-repeat;*/
margin: 0px;
margin-left: 10px;
}



a
{
    color:#036;
}

a:hover, a:active, a:focus {
    color: #D54E21;
}

h1
{
	font-size:14px;
	color:#333333;
}
.name-user-color1
{
    color: #006599;
    font-weight: bold;
    text-decoration: none;
    font-size: 16px;      
    font-family: tahoma,verdana,arial,sans-serif;     
    text-align: center;
    margin-top: 30px;
}

</style>    
</head>
<body>
    <table id="background-image" summary="Meeting Results">
<thead>
    <tr>
        <th scope="col">ID</th>
        <th scope="col">Nombre</th>
        <th scope="col">Puntaje</th>
    </tr>
</thead>
<tfoot>
	<tr>
    	<td colspan="3">
            
        </td>
    </tr>
</tfoot>
<tbody>        
<?php
    
    //Variables Recibidas     
/*   $_POST['var_nombre'] = "Daniel";
    $_POST['var_paterno'] = "Quino";
    $_POST['var_dni'] = "123456";
    $_POST['var_fono'] = "12345";
    $_POST['var_mail'] = "daniel@gmail";
    $_POST['var_materno'] = "angeles";
    $_POST['var_cel'] = "456789";

  */      
            //Insercion de prueba
            
            
            
            $sql_verificar = "SELECT * from gmv_top5 order by puntaje DESC";
            $result2 = mysql_query($sql_verificar);

           
       
            while ($row2 = mysql_fetch_array($result2))
            {

                    echo '<tr>';	
                        echo '<td>'.$row2["id"].'</td>';  
                        echo '<td>'.$row2["nombre"].'</td>';  
                        echo '<td>'.$row2["puntaje"].'</td>';
                    echo '<tr>';                   
                
            }
       

    
?>
</tbody>
</table>
</body>
</html>    